12b397d9aa5d2c78f8911a46e7d61d7fca30256f,src/main/java/org/mafagafogigante/dungeon/commands/IssuedCommandProcessor.java,IssuedCommandProcessor,evaluateIssuedCommand,#IssuedCommand#,37

Before Change


  public static IssuedCommandEvaluation evaluateIssuedCommand(@NotNull IssuedCommand issuedCommand) {
    CommandSet collection;
    String commandToken;
    if (issuedCommand.getTokens().length > 1 && CommandSets.hasCommandSet(issuedCommand.getTokens()[0])) {
      collection = CommandSets.getCommandSet(issuedCommand.getTokens()[0]);
      commandToken = issuedCommand.getTokens()[1];
    } else {
      collection = CommandSets.getCommandSet("default");

After Change


  public static IssuedCommandEvaluation evaluateIssuedCommand(@NotNull IssuedCommand issuedCommand) {
    CommandSet collection;
    String commandToken;
    if (issuedCommand.getTokens().size() > 1 && CommandSets.hasCommandSet(issuedCommand.getTokens().get(0))) {
      collection = CommandSets.getCommandSet(issuedCommand.getTokens().get(0));
      commandToken = issuedCommand.getTokens().get(1);
    } else {
      collection = CommandSets.getCommandSet("default");